const BASE_URL = 'http://localhost:8000';

export function httpPost(url, data) {
  return new Promise((resolve, reject) => {
    axios
      .post(BASE_URL + url, data)
      .then((res) => resolve(res.data))
      .catch((err) => reject(err));
  });
}
